package cn.exrick.xboot.modules.content.service.mybatis;

import cn.exrick.xboot.modules.base.dao.mapper.PermissionMapper;
import cn.exrick.xboot.modules.base.entity.Permission;
import cn.exrick.xboot.modules.content.dao.mapper.HontPermissionMapper;
import cn.exrick.xboot.modules.content.entity.HontPermission;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.annotation.CacheConfig;
import org.springframework.cache.annotation.Cacheable;

import java.util.List;


@CacheConfig(cacheNames = "hontUserPermission")
public interface IHontPermissionService {

    /**
     * 通过用户id获取
     * @param userId
     * @return
     */
    @Cacheable(key = "#userId")
    List<HontPermission> findByUserId(String userId);
}
